function createchars($db,$name,$columns,$unique=null){
	$name=mysql_real_escape_string($name);
	$defs="create table $name (id int,";
	foreach($columns as $col){
		$defs.=mysql_real_escape_string($col).' varchar(56),';
	}
	$defs.='primary key(id),unique(';
	if($unique){
		foreach($unique as $unq){
			$defs.=mysql_real_escape_string($columns[$unq]);
		}
		$defs.='))';
	}
	else $defs.=')';
	echo$defs.' noooo';
	//$q=$db->prepare($defs.')');
    //$q->execute();
}